package com.guigu.ssyx.sys.controller;

import com.atguigu.ssyx.model.sys.Ware;
import com.guigu.ssyx.common.result.Result;
import com.guigu.ssyx.sys.service.WareService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/admin/sys/ware")
public class WareController {

    @Autowired
    private WareService wareService;

    @GetMapping("findAllList")
    public Result findAllList(){
       List<Ware> list= wareService.findAllList();
       return Result.ok(list);
    }
}
